package com.devilvan.hadoop;

public class Test {
    public static void main(String[] args) {
        match();
    }

    public static Boolean match(){
        // 模拟20组数据
        Integer[][] ins = new Integer[][]{
                {0x1001,0x1002,0x1003},
                {0x2001,0x2002,0x2003},
                {0x3001,0x3002,0x3003},
        };
        // 手上待匹配的数据
        Integer[] matches = new Integer[]{0x2005,0x2002,0x2003};

        for (int i = 0; i < ins.length; i++) {
            int size = matches.length;
            for (int j = 0; j < ins[i].length; j++) {
                if (!ins[i][j].equals(matches[j])){
                    System.out.println("第" + i + "组数据不是匹配数据");
                    size--;
                }
            }
            if (size == 3){
                System.out.println("第" + i + "组数据是匹配数据");
                return true;
            }
        }
        System.out.println("没有匹配的数组");
        return false;
    }
}
